#include <vector>
#include <stack>
#include <iostream>
#include <string>
#include <list>
#include <cstdlib>
using namespace std;

template <class T,class Container = vector<T>>
class simulation_stack
{
private:
    Container m_con;
public:
    simulation_stack()

    {

    }
    void push(const T& data)
    {
        m_con.push_back(data);
    }
    void pop()
    {
        m_con.pop_back();
    }
    const T& top() const
    {
        return m_con.back();
    }
    bool empty() const
    {
        return m_con.empty();
    }
    size_t size() const
    {
        return m_con.size();
    }
    ~simulation_stack(){}
};


template <class T,class Container = list<T>>
class simulation_queue
{
private:
    Container m_con;
public:
    simulation_queue()

    {

    }
    void push(const T& data)
    {
        m_con.push_back(data);
    }
    void pop()
    {
        m_con.pop_front();
    }
    const T& top() const
    {
        return m_con.front();
    }
    bool empty() const
    {
        return m_con.empty();
    }
    size_t size() const
    {
        return m_con.size();
    }
    ~simulation_queue(){}
};



// int main()
// {
//     Solution s;
//     s.evalRPN(std::vector<std::string>{"2","1","+","3","*"});
//     return 0;
// }
